home *** CD-ROM | disk | FTP | other *** search
- function adjustView()
- {
- mc[text].scroll = Math.round(mc[text].maxscroll - (mc[text].maxscroll - 1) * ((slider.max - slider._y) / (slider.max - slider.min)));
- }
- function adjustSlider(direction)
- {
- var dy = (slider.max - slider.min) / mc[text].maxscroll;
- if(direction == "up")
- {
- if(slider._y >= slider.min)
- {
- if(slider.min < slider._y - dy)
- {
- slider._y -= dy;
- }
- else
- {
- slider._y = slider.min;
- }
- }
- }
- else if(slider.max >= slider._y)
- {
- if(slider._y + dy < slider.max)
- {
- slider._y += dy;
- }
- else
- {
- slider._y = slider.max;
- }
- }
- }
- function setHeight(H)
- {
- if(0 < H)
- {
- this.down._y = H - this.down._height - this.up._height;
- this.frame._height = H - this.down._height - this.up._height;
- }
- }
- function testIfNeeded()
- {
- this._visible = 1 < mc[text].maxscroll;
- trace(mc[text].maxscroll);
- }
-